package com.um.jdy.platform.base.entity.dto;

import com.um.springboot.starter.orm.params.PageDTO;
import com.um.springboot.starter.orm.params.PageParams;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

@Data
public class ProblemPageDTO extends PageDTO {

    @ApiModelProperty("问题")
    private String title;

    @ApiModelProperty("设备类型")
    private String deviceType;

    @Override
    public PageParams toPageParams() {
        PageParams pageParams = toPageParams(
                new String[]{"title","deviceType"},
                new String[]{"title","device_type"});
        pageParams.getCondition().put("orderby", "sort_no asc");
        return pageParams;
    }
}
